<template>
	<view>
		<view style="z-index: 1;" class="foot cu-bar bg-white tabbar">
		    <view @click="navChange(item.page)" class="action" v-for="(item,index) in tabBar.list" :key="item.page">
		        <view class="cuIcon-cu-image">
		            <image :src="item.iconPath" v-if="curPage!==item.page"></image>
		            <image :src="item.selectedIconPath" v-if="curPage===item.page"></image>
		        </view>
		        <view :class="curPage===item.page?tabBar.selectedTextColor:tabBar.textColor">{{item.text}}</view>
		    </view>
		</view>
	</view>
</template>

<script>
	var _self;
	export default {
		name:'mySearch',
		data() {
			return {
				
			};
		},
		
		props:{
			tabBar:{
			    type:Object,
			    value:{}
			},
			curPage:{
			    type: String,
			    value: ''
			}
		},
		
		methods:{
			//跳转页面函数
			navChange(e){
				console.log(e);
				_self.$emit('setCurPage',e);
				
			    // this.triggerEvent('setCurPage',this.properties.curPage);
			},
		},
		
		created() {
			_self = this;
		}
		
	}
</script>

<style>

</style>
